<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title>15-数组排序sort</title>
	</head>
	<body>
		<script type="text/javascript">
			var arr = [3,1,7,90,100,2];
			arr.sort(function(a,b){
				//升序
				//return a-b;
				return b-a;
			});
			console.log(arr);
			
		</script>
	</body>
</html>
